package com.emcom.gotour.mvc.message;

import javax.servlet.http.HttpServletRequest;

import org.springframework.context.MessageSource;

import com.emcom.gotour.utils.LocaleUtils;

public enum MenuMessage {
	HOME("menu.home"),
	ZHOU_BIAN("menu.zhouBian"),
	GUO_NEI("menu.guoNei"),
	CHU_JING("menu.chuJing"),
	JIU_DIAN("menu.jiuDian"),
	JING_DIAN("menu.jingDian"),
	TRAINING("menu.training"),
	AN_LI("menu.anLi"),
	CHINESE("menu.chinese"),
	ENGLISH("menu.english"),
	ZHOU_BIAN_IMAGE_URL("menu.zhouBian.image.url"),
	GUO_NEI_IMAGE_URL("menu.guoNei.image.url"),
	CHU_JING_IMAGE_URL("menu.chuJing.image.url"),
	JIU_DIAN_IMAGE_URL("menu.jiuDian.image.url"),
	JING_DIAN_IMAGE_URL("menu.jingDian.image.url"),
	TRAINING_IMAGE_URL("menu.training.image.url"),
	AN_LI_IMAGE_URL("menu.anLi.image.url");
	private String message;
	private MenuMessage(String message) {
		this.message = message;
	}
	public String value(HttpServletRequest request, MessageSource messageSource) {
		return messageSource.getMessage(message, null, LocaleUtils.getLocale(request));
	}
}
